package cn.wolfcode.mapper;

import cn.wolfcode.domain.Appointment;
import cn.wolfcode.qo.QueryObject;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface AppointmentMapper {
    int deleteByPrimaryKey(Long id);

    int insert(Appointment record);

    Appointment selectByPrimaryKey(Long id);

    List<Appointment> selectAll();

    int updateByPrimaryKey(Appointment record);

    List<Appointment> selectForList(QueryObject qo);

    /**
     * 修改状态
     * @param id 需要修改的id
     * @param status 修改成什么状态
     */
    void updateStatus(@Param("id") Long id, @Param("status") Long status);

    /**
     * 通过流水号获取数据
     * @param appointmentAno 流水号
     * @return
     */
    Appointment selectByAno(String appointmentAno);
}